# Maintainer: Jan Alexander Steffens (heftig) <heftig@archlinux.org>
# Contributor: Jan de Groot <jgc@archlinux.org>

pkgname=mobile-broadband-provider-info
pkgver=20210805
pkgrel=1
pkgdesc="Network Management daemon"
url="https://gitlab.gnome.org/GNOME/mobile-broadband-provider-info"
arch=(any)
license=(custom)
makedepends=(git libxslt)
_commit=11f2247eccd3c161b8fd9b41143862e9fb81193c
source=("git+https://gitlab.gnome.org/GNOME/mobile-broadband-provider-info.git#commit=$_commit")
sha256sums=('SKIP')

pkgver() {
  cd $pkgname
  git describe --tags | sed 's/-/+/g'
}

prepare() {
  cd $pkgname
  NOCONFIGURE=1 ./autogen.sh
}

check() {
  cd $pkgname
  make check
}

build() {
  cd $pkgname
  ./configure --prefix=/usr
  make
}

package() {
  cd $pkgname
  make DESTDIR="$pkgdir" install
  install -Dt "$pkgdir/usr/share/licenses/$pkgname" -m644 COPYING
}
